/*******************************************************************************
 * Copyright (c) 2022 BestSolution.at and others.
 *  
 * This program and the accompanying materials are made available under the
 * terms of the Eclipse Public License v.2.0 which is available at
 * https://www.eclipse.org/legal/epl-2.0.
 *  
 * SPDX-License-Identifier: EPL-2.0
 *  
 * Contributors:
 *     BestSolution.at - initial API and implementation
 *******************************************************************************/
/*
 * generated by Xtext
 */
package org.eclipse.fx.ide.l10n.ui;

import org.eclipse.fx.ide.l10n.ui.highlighting.NLSHighlightingCalculator;
import org.eclipse.fx.ide.l10n.ui.highlighting.NLSHighlightingConfiguration;
import org.eclipse.fx.ide.l10n.ui.highlighting.TokenToAttributeIdMapper;
import org.eclipse.ui.plugin.AbstractUIPlugin;
import org.eclipse.xtext.ui.editor.XtextEditor;
import org.eclipse.xtext.ui.editor.syntaxcoloring.AbstractAntlrTokenToAttributeIdMapper;
import org.eclipse.xtext.ui.editor.syntaxcoloring.IHighlightingConfiguration;
import org.eclipse.xtext.ui.editor.syntaxcoloring.ISemanticHighlightingCalculator;

import com.google.inject.Binder;
import com.google.inject.name.Names;

/**
 * Use this class to register components to be used within the IDE.
 */
public class NLSDslUiModule extends org.eclipse.fx.ide.l10n.ui.AbstractNLSDslUiModule {
	public NLSDslUiModule(AbstractUIPlugin plugin) {
		super(plugin);
	}

	@Override
	public void configure(Binder binder) {
		super.configure(binder);

		binder.bindConstant().annotatedWith(Names.named(XtextEditor.KEY_BINDING_SCOPE))
		.to("org.eclipse.fx.ide.l10n.ui.NLSEditorScope");
		binder.bind(AbstractAntlrTokenToAttributeIdMapper.class).to(TokenToAttributeIdMapper.class);
		binder.bind(IHighlightingConfiguration.class).to(NLSHighlightingConfiguration.class);
		binder.bind(ISemanticHighlightingCalculator.class).to(NLSHighlightingCalculator.class);
	}

}
